/**
 * 
 */
package com.logistics.web;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;

import com.logistics.Tips;
import com.logistics.admin.AdminGenericBaseAction;
import com.logistics.service.TipsService;

/**
 * @author hzz
 *
 * 2014年5月12日
 */

@Component("tipsAdminAction")
@Scope("prototype")
public class TipsAdminAction extends AdminGenericBaseAction<Tips, TipsService> {
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 7737687473996698996L;
	
	private TipsService service;

	@Autowired
	public void setService(TipsService service) {
		this.service = service;
	}

	@Override
	public TipsService getService() {
		return service;
	}

	private Tips tips;
	
	public Tips getTips() {
		return tips;
	}

	public void setTips(Tips tips) {
		this.tips = tips;
	}

	@Override
	protected Tips initEntityForAdd() {
		return tips;
	}
	
	@Override
	protected void initEditForm() {
		tips = service.getById("1");
	}

}
